<?php

namespace app\admin\controller;

use app\Request;
use app\Request as R;
use app\admin\Validate;
use app\admin\model\AdminUser;
use app\admin\Menu;
use app\admin\middleware\Login;

class Index extends BaseController{



    function index(Request $req)
    {
        return view("/index",[
            'menu'=>app(Menu::class)->getMenu(),
            'user'=>$req->getUser()
        ]);
    }

    function main(R $r)
    {
        /**
         * @var \think\DbManager $query
         */
        $query = app(\think\DbManager::class);
        return view('/main',[
            'req'=>$r,
            'query'=>$query
        ]);
    }
    
}